// Fill out your copyright notice in the Description page of Project Settings.

#pragma once

#include "CoreMinimal.h"
#include "Abilities/GameplayAbility.h"
#include "Abilities/Tasks/AbilityTask_PlayMontageAndWait.h"
#include "BaseGameplayAbility.generated.h"


/**
 * 
 */
UCLASS()
class SSHOOT_API UBaseGameplayAbility : public UGameplayAbility
{
	GENERATED_BODY()

public:
	UBaseGameplayAbility();
public:
	UFUNCTION(BlueprintCallable, Category = "UBaseGameplayAbility|Tasks", meta = (DisplayName = "PlayMontageAndWait"))
	UAbilityTask_PlayMontageAndWait* CreatePlayMontageAndWaitProxy(
		FName TaskInstanceName,
		UAnimMontage* InMontageToPlay,
		float Rate = 1.f,
		FName StartSection = NAME_None,
		bool bStopWhenAbilityEnds = true,
		float AnimRootMotionTranslationScale = 1.f,
		float StartTimeSeconds = 0.f);


	//用于Montage的播放
	UAbilityTask_PlayMontageAndWait*
	PlayMontage(UAnimMontage*  MontageToPlay, FName StartSection = NAME_None);
};
